package org.hako.recite.word.review;

import java.util.ArrayList;
import java.util.List;

import org.hako.recite.word.model.Word;

/**
 * Simple implement of {@link ReviewWordsProvider}. Just for development and
 * test.
 * 
 * @since 0.4.10
 * @author <a href="mailto:xnnyygn@gmail.com">xnnyygn</a>
 */
public class SimpleReviewWordsProvider implements ReviewWordsProvider {

	private String[] columnTitles;
	private List<Word> words;

	/**
	 * Create
	 */
	public SimpleReviewWordsProvider() {
		super();
		columnTitles = new String[] { "Column A", "Column B" };
		words = new ArrayList<Word>();
		words.add(new Word("a", "apple"));
		words.add(new Word("b", "boy"));
		words.add(new Word("c", "cat"));
	}

	@Override
	public int getCount() {
		return words.size();
	}

	@Override
	public Word get(int index) {
		return words.get(index);
	}

	@Override
	public String[] getColumnTitles() {
		return columnTitles;
	}

}
